package chapter10;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.math.BigInteger;

/**
 * Created with IntelliJ IDEA.
 * Description:
 *
 * @author lzy
 * @create 2018-03-21 下午3:34
 */
public class NumberTest {
    private static final Logger LOGGER = LoggerFactory.getLogger(RandomTest.class);

    public static void main(String[] args) {
        BigInteger bigA = new BigInteger("23213213213213");
        BigInteger bigB = new BigInteger("233213213");

        LOGGER.info("bigAxbigB={}", bigA.multiply(bigB));
        LOGGER.info("bigA/bigB={}", bigA.divide(bigB));

        BigInteger[] reslut = bigA.divideAndRemainder(bigB);
        LOGGER.info("bigA/bigB={},..{}", reslut[0], reslut[1]);
    }
}
